<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<#include "/common/context.ftl">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>
	用户管理
</title>
<link type="text/css" rel="stylesheet" href="../jquery/themes/default/easyui.css"/>
<link type="text/css" rel="stylesheet" href="../jquery/themes/icon.css"/>
<link type="text/css" rel="stylesheet" href="../css/style_common.css"/>
<script type="text/javascript" language="javascript" src="../jquery/jquery-1.4.2.min.js"></script>
<script type="text/javascript" language="javascript" src="../jquery/jquery.easyui.min.js"></script>
<script type="text/javascript" language="javascript" src="../js/util.js"></script>
<script type="text/javascript" language="javascript" src="../js/tabpane.js"></script>
<script type="text/javascript" language="javascript" src="../js/json2.js"></script>
<script type="text/javascript" language="javascript" src="../js/manager/account.js"></script>
<script type="text/javascript" language="javascript" src="../js/manager/uploadPreview.js"></script>
</head>
<script>
	$(function(){
		util.ready();
		//建议在#imgDiv的父元素上加个overflow:hidden;的css样式
        $("#photoUrl").uploadPreview({ width: 200, height: 200, imgDiv: "#imgDiv", imgType: ["bmp", "gif", "png", "jpg"] });
       
	});
</script>
<body>
  <#include "/common/manager_user_header.ftl">
<div class="box">
  <!--头部-->
  <#include "/common/page_header.ftl">
  <!--导航部分-->
  <#include "navigation.ftl">
  <!--左侧部分-->
  <#include "index_menu.ftl">
  <!--右侧部分-->
  <div class="right border_lan">
		<div class="lei_title">
			<h4>添加用户</h4>
		</div>
			<div class="lei_title_box">
				<form id="user_form">
					<table>
						<tr>
							<td height="28px">账号：</td>
							<td height="28px"><input type="text" id="loginName" name="loginName" class="easyui-validatebox" required="true" validType="length[3,12]"/></td>
						</tr>
						<tr>
							<td height="28px">密码：</td>
							<td height="28px"><input type="password" id="pwd_new" name="password" class="easyui-validatebox" required="true" validType="length[3,12]"/></td>
						</tr>
						<tr>
							<td height="28px">确认密码：</td>
							<td height="28px"><input type="password" id="pwd_ck" class="easyui-validatebox" required="true" validType="length[3,12]"/></td>
						</tr>
						<tr>
							<td height="28px">用户名：</td>
							<td height="28px"><input type="text" id="userName" name="userName" class="easyui-validatebox" required="true" validType="length[3,12]"/></td>
						</tr>
						<tr>
							<td height="28px">邮箱：</td>
							<td height="28px"><input type="text" id="email" name="email" class="easyui-validatebox" validType="email"/></td>
						</tr>
						<tr>
							<td height="28px">电话：</td>
							<td height="28px"><input type="text" id="phone" name="phone" class="easyui-validatebox" validType="phone"/></td>
						</tr>
						<tr>
							<td height="28px">角色：</td>
							<td height="28px"><select id="role" name="role">
								<option value="0">管理员</option>
								<option value="1">操作员</option>
								<option value="2" selected>会员</option>
							</select></td>
						</tr>
						<tr>
							<td height="28px">头像：</td>
							<td height="28px"><input type="file" id="photoUrl" name="photoUrl" onChange="util.checkImageFormat(this)"/>
								<button onClick="#">上传</button>
							</td>
						</tr>
					</table>
					</form>
					<div style="overflow: hidden; border: 1px dashed red;width:200px;height:200px ">
				        <div id="imgDiv">图片预览区
				        </div>
    				</div>
    				<div class="divline"></div>
					<div class="toolbar">
						<a href="#" class="easyui-linkbutton" iconCls="icon-ok" onClick="Account.addUser()">提交</a>
					</div>
  			</div>
  </div>
  
  <#include "/common/page_footer.ftl">
</div>
</body>
</html>
